package com.fsy.spring.observer;

import java.util.Objects;

/**
 * Created by shuangyu.feng on 2017/7/27.
 */
public class Test {

	public static void main(String[] args){
		AbstractOberser abstractOberser = new Myself();
		IObserver iObserver1 = new Observer("fsy");
		IObserver iObserver2 = new Observer("dlx");
		IObserver iObserver3 = new Observer("sym");
		IObserver iObserver4 = new Observer("srm");
		IObserver iObserver5 = new Observer("ljw");
		IObserver iObserver6 = new Observer("ln");
		abstractOberser.add(iObserver1);
		abstractOberser.add(iObserver2);
		abstractOberser.add(iObserver3);
		abstractOberser.add(iObserver4);
		abstractOberser.add(iObserver5);
		abstractOberser.add(iObserver6);

		abstractOberser.doSelfWork();
	}
}
